package com.example.excelimport.util;

import com.example.excelimport.config.FilePathConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
@Slf4j
@Component
public class TempDirInitializer {

    @Autowired
    private FilePathConfig filePathConfig;

    @PostConstruct
    public void init() {
        filePathConfig.ensureTempDirExists();
        log.info("临时目录初始化完成: {}", filePathConfig.getTempDir());
    }
}
